package com.itheima.service;

import com.alibaba.dubbo.config.annotation.Service;
import com.itheima.dao.UserDao;
import com.itheima.pojo.SysUser;
import org.springframework.beans.factory.annotation.Autowired;

@Service
public class UserServiceImpl implements UserService {

	@Autowired
	UserDao userDao;

	@Override
	public boolean login(String username, String password) {
		System.out.println("service_provide...u:"+username+" p:"+password);
		return "admin".equals(username) && "123".equals(password);
	}

	@Override
	public SysUser findByUsername(String username) {
		return userDao.findByUsername(username);
	}
}